package com.pubinfo.passbook.engine.cell.single;

import com.pubinfo.passbook.engine.constants.ComputeChainType;
import com.pubinfo.passbook.engine.constants.ComputeResultType;

import java.math.BigDecimal;

/**
 * 归零
 *
 * @author zhouch
 * @date 2022/1/13 10:27
 */
public class ZeroUnit<T> extends ComputeSingleUnit<T> {
    @Override
    public BigDecimal compute(T data, BigDecimal result) {
        outputComputeMessage("0");
        return BigDecimal.ZERO;
    }

    @Override
    public String getChainType() {
        return ComputeChainType.COMMON;
    }

    @Override
    public String getResultType() {
        return ComputeResultType.NUMBER;
    }

    @Override
    public String getName() {
        return "归零";
    }
}
